CC = g++ -O0 -Wno-deprecated -I.

CC_OPTIONS= -g -c -std=c++0x

COMPILEER= $(CC) $(CC_OPTIONS)

BINARIES= MIPSsim

OBJECTS= Table.o Instruction.o Math.o Utility.o

all: $(BINARIES)

MIPSsim: $(OBJECTS) main.o
	$(CC) -o MIPSsim main.o $(OBJECTS)

main.o: main.cpp
	$(CC) $(CC_OPTIONS) main.cpp

Table.o: Table.cpp
	$(CC) $(CC_OPTIONS) Table.cpp

Instruction.o: Instruction.cpp
	$(CC) $(CC_OPTIONS) Instruction.cpp
	
Math.o: Math.cpp
	$(CC) $(CC_OPTIONS) Math.cpp
	
Utility.o: Utility.cpp
	$(CC) $(CC_OPTIONS) Utility.cpp

clean: 
	rm -f *.txt
	rm -f *.o
	rm -f $(BINARIES)
